package com.xtq.springcloud;

import com.xtq.springcloud.config.RibbonRule;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration;
import org.springframework.cloud.client.discovery.EnableDiscoveryClient;
import org.springframework.cloud.netflix.eureka.EnableEurekaClient;
import org.springframework.cloud.netflix.ribbon.RibbonClient;

/**
 * @author: xietianqi
 * @create: 2024-01-23 08:41
 * @description: Springboot启动器
 **/
// 如果误引入数据库相关依赖,需要加排除
@SpringBootApplication(exclude = DataSourceAutoConfiguration.class)
@EnableEurekaClient
@EnableDiscoveryClient //启用服务发现
//指定负载均衡算法
@RibbonClient(name = "MEMBER_SERVICE_PROVIDER_URL",configuration = RibbonRule.class)
public class MemberConsumerApplication {
	public static void main(String[] args) {
		SpringApplication.run(MemberConsumerApplication.class, args);
	
	}
}
